﻿using LaunchAllaround.DesignPattern.MVC;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace LaunchAllaround
{
    /// <summary>
    /// Logique d'interaction pour Footer.xaml
    /// </summary>
    public partial class Footer : UserControl
    {

        public static readonly Footer myself = new Footer();

        private Footer()
        {
            InitializeComponent();
        }

        public void Refresh(string message, Color color)
        {
            this.message.Content = message;
            this.Background = new SolidColorBrush(color);
        }

        public void PrintInfo(string message)
        {
            Color color = (Color)ColorConverter.ConvertFromString("#007ACC");
            this.Refresh(message, color);
        }

        public void PrintError(string message)
        {
            Color color = (Color)ColorConverter.ConvertFromString("#CA5100");
            this.Refresh(message, color);
        }
    }
}
